import React, { Component } from 'react';

// import {Button} from 'antd-mobile'

import 'components/common/search/search.css'
import {
  Route,
  Switch,
  Redirect,
  withRouter
} from 'react-router-dom'

import Home from "pages/home/index"
import Select from "pages/select/Select"
import Shopcar from "pages/shopcar/Shopcar"
import Mine from "pages/mine/Mine"
import SearchPage from 'components/common/search/SearchPage'
class App extends Component {

  render() {
    return (
     <Switch>
      
      {/* <Redirect from = "/" to="/home" exact></Redirect> */}
      {/* <Route to="/home" component={Home} exact></Route> */}
      <Route path="/home" component = {Home}></Route>
      <Route path="/select" component = {Select}></Route>
      <Route path="/shopcar" component = {Shopcar}></Route>
      <Route path="/mine" component = {Mine}></Route>
      {/* <Route path="/select" component = {SearchPage}></Route> */}
      <Route path="/search" component = {SearchPage} exact></Route>
     </Switch>
    );
  }
}

export default withRouter(App)
